package com.yanmaohu.yulia.statement;

import com.yanmaohu.yulia.bean.Identifier;

/**
 * @author Bright Lee
 */
public final class ReleaseSavepointStatement implements SqlTransactionStatement, Statement {

    private int beginIndex;
    private int endIndex;
    private Identifier savepointSpecifier;

    public ReleaseSavepointStatement(int beginIndex, Identifier savepointSpecifier) {
        this.beginIndex = beginIndex;
        this.endIndex = savepointSpecifier.getEndIndex();
        this.savepointSpecifier = savepointSpecifier;
    }

    @Override
    public int getBeginIndex() {
        return beginIndex;
    }

    @Override
    public int getEndIndex() {
        return endIndex;
    }

    public Identifier getSavepointSpecifier() {
        return savepointSpecifier;
    }

}
